<link rel="stylesheet"  type="text/css"  href="../css/pay.css"/>
<div  ng-controller="payCtrl">
    <ul class="navigation">
        <li><a href="#/product_list">Let's Go</a></li>
        <li><a id="home" href="#/home">主页</a></li>
        <li><a id="product" href="#/product_list">商品列表</a></li>
        <li class="all_cart"><img  src="../shopping_cart.png"/><a class="cart" href="#/cart" ng-model="sum_count">购物车({{sum_count}})</a> </li>
    </ul>
    <div class="form">
        <div class="caption">
            <caption>购物清单</caption>
        </div>
        <p class="time">{{date}}</p>
        <table id="product_list">
            <tr>
                <th class="classification">分类</th>
                <th class="name">名称</th>
                <th class="price">单价（元）</th>
                <th class="unit">单位</th>
                <th class="count">数量</th>
                <th class="money">小计</th>
            </tr>
            <tr ng-repeat="item in goods_infos">
                <td>{{item.classification}}</td>
                <td>{{item.name}}</td>
                <td>{{item.price}}</td>
                <td>{{item.unit}}</td>
                <td>{{item.count}}</td>
                <td>{{item.actually}}元  <span ng-if="judgment_subtotal(item)">(原价：{{item.original}}元) </span></td>
            </tr>
        </table>
        <div ng-if="free">
            <div class="caption">
                <caption class="free">赠送商品</caption>
            </div>
            <table id="save_table">
                <tr>
                    <th>分类</th>
                    <th>名称</th>
                    <th>数量</th>
                </tr>
                <tr ng-repeat="item in save_infos">
                    <th>{{item.classification}}</th>
                    <th>{{item.name}}</th>
                    <th>{{item.pro_count}}</th>
                </tr>
            </table>
        </div>
        <div class="sum" ng-model="sum_money">总计：{{sum_money}}<a id="sum_money"></a> 元</div>
        <div class="save" ng-model="save_money" ng-if="free">节省：{{save_money}}<a id="save"></a> 元</div>
        <button class="pay" ng-click="confirm()">确认</button>
    </div>
</div>

